--[[		   d(^_^o)
]]--		  by Lolzen
local hp, loadInZone, text, text2

loadInZone = {}
loadInZone["Alterac Valley"] = "1:1"
loadInZone["Arathi Basin"] = "1:1"
loadInZone["Warsong Gulch"] = "1:1"
loadInZone["Eye of the Storm"] = "1:1"

local HPframe = CreateFrame("Frame",nil,UIParent)
HPframe:SetPoint("TOP", -42, -75)
HPframe:SetHeight(32)
HPframe:SetWidth(32)

local tex = HPframe:CreateTexture(nil, "ARTWORK")

text = HPframe:CreateFontString(nil, "OVERLAY")
text:SetFontObject(ErrorFont)
text:SetFont("Fonts\\FRIZQT__.TTF", 10)
text:SetPoint("LEFT",HPframe,"RIGHT", 0, 6)

text2 = HPframe:CreateFontString(nil, "OVERLAY")
text2:SetFontObject(ErrorFont)
text2:SetFont("Fonts\\FRIZQT__.TTF", 10)
text2:SetPoint("LEFT",HPframe,"RIGHT", 0, -6)

function HPframe:event(event) 
	local zone = GetRealZoneText()
	
	if loadInZone[zone] then
		_, hp = GetPVPSessionStats() 
		tex:SetTexture("Interface\\AddOns\\d(^_^o)\\textures\\Honor")
		tex:SetAllPoints(HPframe)
		text:SetText("Honor: "..GetHonorCurrency()) 
		text2:SetText("Earned Today: "..hp) 
	else
		tex:SetTexture("Interface\\AddOns\\d(^_^o)\\textures\\Honor2")
		text:SetText(nil)
		text2:SetText(nil)
	end
end

HPframe:RegisterEvent"MINIMAP_ZONE_CHANGED"
HPframe:RegisterEvent"ZONE_CHANGED_INDOORS"
HPframe:RegisterEvent"ZONE_CHANGED"
HPframe:RegisterEvent"ZONE_CHANGED_NEW_AREA"
HPframe:RegisterEvent("HONOR_CURRENCY_UPDATE")
HPframe:RegisterEvent"PLAYER_ENTERING_WORLD"
HPframe:SetScript("OnEvent", HPframe.event)